// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3) 
// Source File Name:   SourceFile

package com.sgame.android.network.util;

import java.security.InvalidKeyException;
import java.security.NoSuchAlgorithmException;

import javax.crypto.Mac;
import javax.crypto.spec.SecretKeySpec;

public final class SecretKey
{

    public static String getKey(String s, String s1)
    {
        String s2 = "";
        SecretKeySpec key = new SecretKeySpec(s.getBytes(), "HmacSHA1");
        Mac mac;
        try {
			(mac = Mac.getInstance("HmacSHA1")).init(key);
	        s = android.util.Base64.encodeToString(mac.doFinal(s1.getBytes()), 0);
	        s2 = s.trim();
	        return s2;
		}
        catch (InvalidKeyException e) {
		}
        catch (NoSuchAlgorithmException e) {
		}
        return null;
    }
}
